//
//  ZLQFirstPageCell.swift
//  GoTravel
//
//  Created by lanou3g on 16/3/9.
//  Copyright © 2016年 SHH. All rights reserved.
//

import UIKit

class ZLQFirstPageCell: UITableViewCell {

    var nameImage:UIImageView?
    var nameL:UILabel?
    var numberL:UILabel?
    
    override func awakeFromNib() {
        super.awakeFromNib()
        // Initialization code
    }

    override init(style: UITableViewCellStyle, reuseIdentifier: String?) {
        super.init(style: style, reuseIdentifier: reuseIdentifier)
        
        nameImage = UIImageView(frame: CGRectMake(self.contentView.frame.size.width*0.025,self.contentView.frame.size.height*0.05,self.contentView.frame.size.width*0.25,self.contentView.frame.size.height*0.9))
        nameImage?.backgroundColor = UIColor.whiteColor()
        nameImage?.layer.masksToBounds = true
        nameImage?.layer.cornerRadius = 10
        self.addSubview(nameImage!)
        
        nameL = UILabel(frame: CGRectMake(self.contentView.frame.size.width*0.37,self.contentView.frame.size.height*0.2,self.contentView.frame.size.width*0.6,self.contentView.frame.size.height*0.2))
        nameL?.font = UIFont.systemFontOfSize(19)
        nameL?.text = "纽约"
        self.addSubview(nameL!)
        
        numberL = UILabel(frame: CGRectMake(self.contentView.frame.size.width*0.37,self.contentView.frame.size.height*0.45,self.contentView.frame.size.width*0.6,self.contentView.frame.size.height*0.2))
        numberL?.font = UIFont.systemFontOfSize(14)
        numberL?.text = "103条旅行灵感"
        self.addSubview(numberL!)
        
        
        
    }

    override func layoutSubviews() {
        super.layoutSubviews()
        
        nameImage?.frame = CGRectMake(self.contentView.frame.size.width*0.025,self.contentView.frame.size.height*0.05,self.contentView.frame.size.width*0.25,self.contentView.frame.size.height*0.9)
        nameL?.frame = CGRectMake(self.contentView.frame.size.width*0.37,self.contentView.frame.size.height*0.2,self.contentView.frame.size.width*0.6,self.contentView.frame.size.height*0.2)
        numberL?.frame = CGRectMake(self.contentView.frame.size.width*0.37,self.contentView.frame.size.height*0.45,self.contentView.frame.size.width*0.6,self.contentView.frame.size.height*0.2)
        
    }
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    override func setSelected(selected: Bool, animated: Bool) {
        super.setSelected(selected, animated: animated)

        // Configure the view for the selected state
    }

}
